<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>SDL2_gfx: SDL2_gfx - Graphics primitives and surface functions for SDL2</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />



</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">SDL2_gfx
   &#160;<span id="projectnumber">1.0.1</span>
   </div>
   <div id="projectbrief">GraphicsprimitivesandsurfacefunctionsforSDL2</div>
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.8.0 -->
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li class="current"><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="headertitle">
<div class="title">SDL2_gfx - Graphics primitives and surface functions for SDL2 </div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><h2><a class="anchor" id="contact_sec"></a>
Contact and License</h2>
<p>Email aschiffler at ferzkopp dot net to contact the author or better check author's homepage at <a href="http://www.ferzkopp.net">http://www.ferzkopp.net</a> for the most up-to-date contact information.</p>
<p>This library is licenced under the zlib License, see the file LICENSE for details.</p>
<h2><a class="anchor" id="intro_sec"></a>
Introduction</h2>
<p>The SDL2_gfx library provides the basic drawing functions such as lines, circles or polygons provided by SDL_gfx on SDL2 against renderers of SDL2.</p>
<p>The current components of the SDL2_gfx library are:</p>
<ul>
<li>Graphic Primitives (<a class="el" href="_s_d_l2__gfx_primitives_8h.html">SDL2_gfxPrimitives.h</a>, <a class="el" href="_s_d_l2__gfx_primitives_8c.html">SDL2_gfxPrimitives.c</a>)</li>
<li>Surface Rotozoomer (<a class="el" href="_s_d_l2__rotozoom_8h.html">SDL2_rotozoom.h</a>, <a class="el" href="_s_d_l2__rotozoom_8c.html">SDL2_rotozoom.c</a>)</li>
<li>Framerate control (<a class="el" href="_s_d_l2__framerate_8h.html">SDL2_framerate.h</a>, <a class="el" href="_s_d_l2__framerate_8c.html">SDL2_framerate.c</a>)</li>
<li>MMX image filters (<a class="el" href="_s_d_l2__image_filter_8h.html">SDL2_imageFilter.h</a>, <a class="el" href="_s_d_l2__image_filter_8c.html">SDL2_imageFilter.c</a>)</li>
<li>Build-in 8x8 Font (<a class="el" href="_s_d_l2__gfx_primitives__font_8h.html">SDL2_gfxPrimitives_font.h</a>)</li>
</ul>
<p>Note that SDL2_gfx is compatible with SDL version 2.0 (not SDL 1.2).</p>
<h2><a class="anchor" id="install_sec"></a>
Installation</h2>
<h3><a class="anchor" id="unix"></a>
Unix/Linux</h3>
<p>Use the standard autoconf/automake sequence to compile and install the library. </p>
<div class="fragment"><pre class="fragment">        ./autogen.sh    # (optional, recommended)
        ./configure
        make
        make install
</pre></div><p>\subsubsection nommx Linker Configuration</p>
<p>The default location for the installation is /usr/local/lib and /usr/local/include. This libary path may need to be added to the file the linker configuration file: </p>
<div class="fragment"><pre class="fragment">        vi /etc/ld.so.conf
        ldconfig
</pre></div><p>\subsubsection nommx Non-MMX Platforms</p>
<p>To build without MMX code enabled (i.e. ARM, PPC, AMD64 architectures): </p>
<div class="fragment"><pre class="fragment">        ./configure --disable-mmx
        make
        make install
</pre></div><h3><a class="anchor" id="visualstudio"></a>
Windows (VC10, VS2012)</h3>
<p>Open SDL_gfx_VS2010.sln solution file and review README.</p>
<h2><a class="anchor" id="test_sec"></a>
Test Programs</h2>
<p>Change to the ./test directory and run </p>
<div class="fragment"><pre class="fragment">        ./autogen.sh
        ./configure
        make
</pre></div><p> to create several test programs for the libraries functions. This requires the SDL2_gfx library to be previously compiled and installed.</p>
<p>See the source in the test/*.c files for some sample code and implementation hints.</p>
<h2><a class="anchor" id="documentation_sec"></a>
Documentation</h2>
<p>Please refer to the Doxygen-generated API documentation found in the Docs/html folder as well as the test programs in the test folder.</p>
<h2><a class="anchor" id="changelog_sec"></a>
Change Log</h2>
<div class="fragment"><pre class="fragment">SDL2_gfx ChangeLog

Sun, Jun 15, 2014  3:12:31 PM
- fixed roundedBox by rewriting algorithm and base it on filledCircle
- fixed textured polygon algorithm
- updated testgfx extensively (visual accuracy tests, updated tests for textured polygon)
- updated README

Mon, Jun 09, 2014  8:48:50 AM
- removed VS2010 solution files; updated VS2012 solution files for SDL2 updates

Mon, Jun 02, 2014  7:36:24 AM
- add patch for pkg-config support (thanks Sylvain)
- update tests to use SDLTest library
- fix commandline parsing in testgfx

Mon, May 12, 2014  7:29:24 AM
- fixed BoxRGBA size-off-by-1 error (thanks Stefan for reporting)

Sun, Feb 02, 2014 12:00:00 PM
- fixed and optimized rotateSurface90Degrees
- updated testrotozoom to allow specification of test range

Sun, Nov 03, 2013 10:11:16 AM
- updated testgfx program for benchmarking primitive rendering performance
- updated test programs based on VS warnings
- fixed VS2012 solution for Release build
 
Mon, Oct 28, 2013  8:00:05 AM
- bugfix to _aaline special cases
- added image filter functions
- added to documentation
- updated readme and changelog
- updated solutions for VS2010 and VS2012

Tue, Sep 04, 2012  8:27:44 AM
- initial release of development version (partially finished)
</pre></div> </div></div><!-- contents -->


<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.0
</small></address>

</body>
</html>
